package space.sakana.edusysback.entity.paper;

import space.sakana.edusysback.entity.question.type.EssayQuestion;
import space.sakana.edusysback.entity.question.type.MultipleChoice;
import space.sakana.edusysback.entity.question.type.SingleChoice;
import space.sakana.edusysback.entity.question.type.TrueFalseQ;

import java.util.ArrayList;
import java.util.List;

public class FullPaper {

    private int pid;
    private List<SingleChoice> singleChoiceList;
    private List<MultipleChoice> multipleChoiceList;
    private List<TrueFalseQ> trueFalseQList;
    private List<EssayQuestion> essayQuestionList;

    public int getPid() {
        return pid;
    }

    public void setPid(int pid) {
        this.pid = pid;
    }

    public void addSingleChoice(SingleChoice singleChoice){
        if (this.singleChoiceList==null){
            this.singleChoiceList = new ArrayList<>();
        }
        this.singleChoiceList.add(singleChoice);
    }

    public void addMultipleChoice(MultipleChoice multipleChoice){
        if (this.multipleChoiceList==null){
            this.multipleChoiceList = new ArrayList<>();
        }
        this.multipleChoiceList.add(multipleChoice);
    }

    public void addTrueFalseQ(TrueFalseQ trueFalseQ){
        if (this.trueFalseQList==null){
            this.trueFalseQList = new ArrayList<>();
        }
        this.trueFalseQList.add(trueFalseQ);
    }

    public void addEssayQuestion(EssayQuestion essayQuestion){
        if (this.essayQuestionList==null){
            this.essayQuestionList = new ArrayList<>();
        }
        this.essayQuestionList.add(essayQuestion);
    }

    public List<SingleChoice> getSingleChoiceList() {
        return singleChoiceList;
    }

    public void setSingleChoiceList(List<SingleChoice> singleChoiceList) {
        this.singleChoiceList = singleChoiceList;
    }

    public List<MultipleChoice> getMultipleChoiceList() {
        return multipleChoiceList;
    }

    public void setMultipleChoiceList(List<MultipleChoice> multipleChoiceList) {
        this.multipleChoiceList = multipleChoiceList;
    }

    public List<TrueFalseQ> getTrueFalseQList() {
        return trueFalseQList;
    }

    public void setTrueFalseQList(List<TrueFalseQ> trueFalseQList) {
        this.trueFalseQList = trueFalseQList;
    }

    public List<EssayQuestion> getEssayQuestionList() {
        return essayQuestionList;
    }

    public void setEssayQuestionList(List<EssayQuestion> essayQuestionList) {
        this.essayQuestionList = essayQuestionList;
    }
}
